package com.ybkj.o2o.mc.entity;

import com.ybkj.o2o.mc.common.DateField;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;

import java.io.Serializable;
import java.util.Date;
import java.util.List;


/**
 * 乘客所属企业.
 *
 * @author Administrator
 */
public class Enterprise extends AccountBase implements Serializable {

  private Long id;

  private String name;      //企业名称

  private String address;      //企业地址

  private String memo;

  @JsonProperty("grade_id")
  private Long gradeId;      //级别

  @JsonProperty("grade_name")
  private String gradeName;    //级别名称

  private Long companyId;      //公司Id

  private String companyName;  //所属公司名称

  private Long drivingNumberTimes;//代驾次数

  @JsonSerialize(using = DateField.class)
  private Date created;

  private Date updated;

  @JsonIgnore
  private Integer version;

  private String appKey;      //用于区别系统


  public Long getGradeId() {
    return gradeId;
  }

  public void setGradeId(Long gradeId) {
    this.gradeId = gradeId;
  }

  public String getGradeName() {
    return gradeName;
  }

  public void setGradeName(String gradeName) {
    this.gradeName = gradeName;
  }

  public Long getDrivingNumberTimes() {
    return drivingNumberTimes;
  }

  public void setDrivingNumberTimes(Long drivingNumberTimes) {
    this.drivingNumberTimes = drivingNumberTimes;
  }

  private List<Passenger> passengers;  //企业下面的乘客


  public List<Passenger> getPassengers() {
    return passengers;
  }

  public void setPassengers(List<Passenger> passengers) {
    this.passengers = passengers;
  }

  private static final long serialVersionUID = 1L;

  public Long getId() {
    return id;
  }

  public void setId(Long id) {
    this.id = id;
  }

  public String getName() {
    return name;
  }

  public void setName(String name) {
    this.name = name == null ? null : name.trim();
  }

  public String getAddress() {
    return address;
  }

  public void setAddress(String address) {
    this.address = address == null ? null : address.trim();
  }

  public String getMemo() {
    return memo;
  }

  public void setMemo(String memo) {
    this.memo = memo == null ? null : memo.trim();
  }


  public Date getCreated() {
    return created;
  }

  public void setCreated(Date created) {
    this.created = created;
  }

  public Date getUpdated() {
    return updated;
  }

  public void setUpdated(Date updated) {
    this.updated = updated;
  }

  public Integer getVersion() {
    return version;
  }

  public void setVersion(Integer version) {
    this.version = version;
  }

  public String getAppKey() {
    return appKey;
  }

  public void setAppKey(String appKey) {
    this.appKey = appKey == null ? null : appKey.trim();
  }

  public Long getCompanyId() {
    return companyId;
  }

  public void setCompanyId(Long companyId) {
    this.companyId = companyId;
  }

  public String getCompanyName() {
    return companyName;
  }

  public void setCompanyName(String companyName) {
    this.companyName = companyName;
  }

}